<template>
  <div>
    <van-button style="margin-bottom:5px;" type="primary" size="large" @click="goToFrom(1)">寻车</van-button>
    <br>
    <van-button style="margin-bottom:5px;" type="primary" size="large" @click="goToFrom(2)">按揭</van-button>
    <br>
    <van-button type="primary" size="large" @click="goToFrom(3)">设置token</van-button>
  </div>
</template>

<script>
export default {
  data() {
    return {
    }
  },
  methods: {
    goToFrom(n) {
      const jump = {
        1: { path: 'FindCarForm'},
        2: { path: 'MortageForm'},
        3: { path: 'setToken'}
      }
      console.log(jump[n].path)
      this.$router.push({
        name: jump[n].path,
      })
    }
  }
}
</script>

<style>

</style>